← Course index · R314 System & Network
MMIBUT Métiers du Multimédia et de l'Internet · IUT de Vélizy

IPv4 Addressing

Course summary: address structure, special addresses, classes, CIDR notation and private ranges.

CourseNetwork32-bit addresses

01General principles

Computers communicate using the TCP/IP protocols, which use 32-bit addresses. An address is written as 4 numbers from 0 to 255 (4 × 8 bits), in the form xxx.xxx.xxx.xxx, where each xxx is an integer from 0 to 255.

02Address structure

An IP address is made of two distinct parts. Two computers on the same network can't have the same IP address.

Net-ID (network ID)

The left part: designates the network.

Host-ID (machine ID)

The right part: designates the machines on that network.

The netmask sets the length of each part.

03Special IP addresses

Network address

Host-ID made only of 0s: the address represents the network itself.

Broadcast address

Host-ID made only of 1s: the address reaches ALL machines on the network.

Localhost

127.0.0.1 designates the local machine. Used to test the network card.

04Address classes

IP addresses are divided into classes according to the number of bytes used for the network. The first bits determine the class.

ClassNet-ID sizeFirst bitsDefault mask
A8 bits (1 byte)0255.0.0.0
B16 bits (2 bytes)10255.255.0.0
C24 bits (3 bytes)110255.255.255.0

Network capacities

ClassNumber of possible networksMax computers per network
A12616,777,214
B16,38465,534
C2,097,152254

05CIDR notation

Instead of dotted decimal masks (e.g. 255.255.0.0), CIDR (Classless Inter-Domain Routing) notation gives the number of bits used for the Net-ID.

Format

/number of bits

Example

255.255.0.0 → /16

Example

255.255.255.192 → /26

06Private IP addresses (RFC 1918)

Context: ICANN allocates public IPs. To prevent a shortage, ranges were reserved for private use (home, company). These addresses are ignored by Internet routers.
ClassMin usable IPMax usable IPSubnet mask
A10.0.0.110.255.255.254255.0.0.0
B172.16.0.1172.31.255.254255.255.0.0
C192.168.0.1192.168.255.254255.255.255.0